/*
 *
 * This source code is available under the "Simplified BSD license".
 *
 * Copyright (c) 2013, J. Kleiner
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without 
 * modification, are permitted provided that the following conditions are met:
 *
 * 1. Redistributions of source code must retain the above copyright notice, 
 *    this list of conditions and the following disclaimer.
 *
 * 2. Redistributions in binary form must reproduce the above copyright 
 *    notice, this list of conditions and the following disclaimer in the 
 *    documentation and/or other materials provided with the distribution.
 *
 * 3. Neither the name of the original author nor the names of its contributors 
 *    may be used to endorse or promote products derived from this software 
 *    without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 
 * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 
 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED 
 * TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, 
 * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY 
 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 
 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 *
 */
package Xy;

import javax.swing.JFileChooser;
import javax.swing.JOptionPane;

/**
 * This class is designed as a popup menu for an XY display.
 */
public class XyDisplayMenu extends Object {

    JFileChooser mFileChooser;
    
    /**
     * Creates new form XyDisplayMenu
     */
    public XyDisplayMenu() {
        initComponents();
        
        mFileChooser = new JFileChooser( "C:/Tmp" ); // TODO make configurable
    }

    XyDisplay mXyDisplay;
    public void SetXyDisplay( XyDisplay xyd ){
        mXyDisplay = xyd;
    }
    
    public javax.swing.JPopupMenu GetPopup(){
        mCheckBoxMenuItemEnvShow.setSelected(  mXyDisplay.getEnvVisible());
        mCheckBoxMenuItemEnvActive.setSelected(mXyDisplay.getEnvActive());
        mCheckBoxMenuItemMemShow0.setSelected(  mXyDisplay.getMemVisible(0));
        mCheckBoxMenuItemMemShow1.setSelected(  mXyDisplay.getMemVisible(1));
        mCheckBoxMenuItemMemShow2.setSelected(  mXyDisplay.getMemVisible(2));
        mCheckBoxMenuItemMemShow3.setSelected(  mXyDisplay.getMemVisible(3));
        return( mPopupMenu );
    }
    
    /**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        mPopupMenu = new javax.swing.JPopupMenu();
        mMenuEnvelope = new javax.swing.JMenu();
        mCheckBoxMenuItemEnvShow = new javax.swing.JCheckBoxMenuItem();
        mCheckBoxMenuItemEnvActive = new javax.swing.JCheckBoxMenuItem();
        mMenuMem = new javax.swing.JMenu();
        jMenuM0 = new javax.swing.JMenu();
        mCheckBoxMenuItemMemShow0 = new javax.swing.JCheckBoxMenuItem();
        mMenuItemMemCapture0 = new javax.swing.JMenuItem();
        jMenuM1 = new javax.swing.JMenu();
        mCheckBoxMenuItemMemShow1 = new javax.swing.JCheckBoxMenuItem();
        mMenuItemMemCapture1 = new javax.swing.JMenuItem();
        jMenuM2 = new javax.swing.JMenu();
        mCheckBoxMenuItemMemShow2 = new javax.swing.JCheckBoxMenuItem();
        mMenuItemMemCapture2 = new javax.swing.JMenuItem();
        jMenuM3 = new javax.swing.JMenu();
        mCheckBoxMenuItemMemShow3 = new javax.swing.JCheckBoxMenuItem();
        mMenuItemMemCapture3 = new javax.swing.JMenuItem();
        mMenuEdit = new javax.swing.JMenu();
        mMenuEditTitle = new javax.swing.JMenuItem();
        mMenuEditCaption = new javax.swing.JMenuItem();
        mMenuFile = new javax.swing.JMenu();
        mMenuItemFileExportCsv = new javax.swing.JMenuItem();
        mMenuItemFileExportPng = new javax.swing.JMenuItem();
        jSeparator1 = new javax.swing.JPopupMenu.Separator();
        mMenuPeak = new javax.swing.JMenu();
        mMenuItemPeakOff = new javax.swing.JMenuItem();
        mMenuItemPeakPick3 = new javax.swing.JMenuItem();
        mMenuItemPeakPick6 = new javax.swing.JMenuItem();
        mMenuItemPeakPick9 = new javax.swing.JMenuItem();
        mMenuMarkers = new javax.swing.JMenu();
        mMenuMarkersAllOn = new javax.swing.JMenuItem();
        mMenuMarkersAllOff = new javax.swing.JMenuItem();
        mMenuMarkersNextActive = new javax.swing.JMenuItem();

        mMenuEnvelope.setText("Envelope");

        mCheckBoxMenuItemEnvShow.setSelected(true);
        mCheckBoxMenuItemEnvShow.setText("Show");
        mCheckBoxMenuItemEnvShow.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mCheckBoxMenuItemEnvShowActionPerformed(evt);
            }
        });
        mMenuEnvelope.add(mCheckBoxMenuItemEnvShow);

        mCheckBoxMenuItemEnvActive.setSelected(true);
        mCheckBoxMenuItemEnvActive.setText("Active");
        mCheckBoxMenuItemEnvActive.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mCheckBoxMenuItemEnvActiveActionPerformed(evt);
            }
        });
        mMenuEnvelope.add(mCheckBoxMenuItemEnvActive);

        mPopupMenu.add(mMenuEnvelope);

        mMenuMem.setText("Mem");

        jMenuM0.setText("M0");
        jMenuM0.setActionCommand("M0");

        mCheckBoxMenuItemMemShow0.setSelected(true);
        mCheckBoxMenuItemMemShow0.setText("Show");
        mCheckBoxMenuItemMemShow0.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mCheckBoxMenuItemMemShow0ActionPerformed(evt);
            }
        });
        jMenuM0.add(mCheckBoxMenuItemMemShow0);

        mMenuItemMemCapture0.setText("Capture");
        mMenuItemMemCapture0.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuItemMemCapture0ActionPerformed(evt);
            }
        });
        jMenuM0.add(mMenuItemMemCapture0);

        mMenuMem.add(jMenuM0);

        jMenuM1.setText("M1");
        jMenuM1.setActionCommand("M1");

        mCheckBoxMenuItemMemShow1.setSelected(true);
        mCheckBoxMenuItemMemShow1.setText("Show");
        mCheckBoxMenuItemMemShow1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mCheckBoxMenuItemMemShow1ActionPerformed(evt);
            }
        });
        jMenuM1.add(mCheckBoxMenuItemMemShow1);

        mMenuItemMemCapture1.setText("Capture");
        mMenuItemMemCapture1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuItemMemCapture1ActionPerformed(evt);
            }
        });
        jMenuM1.add(mMenuItemMemCapture1);

        mMenuMem.add(jMenuM1);

        jMenuM2.setText("M2");
        jMenuM2.setActionCommand("M2");

        mCheckBoxMenuItemMemShow2.setSelected(true);
        mCheckBoxMenuItemMemShow2.setText("Show");
        mCheckBoxMenuItemMemShow2.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mCheckBoxMenuItemMemShow2ActionPerformed(evt);
            }
        });
        jMenuM2.add(mCheckBoxMenuItemMemShow2);

        mMenuItemMemCapture2.setText("Capture");
        mMenuItemMemCapture2.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuItemMemCapture2ActionPerformed(evt);
            }
        });
        jMenuM2.add(mMenuItemMemCapture2);

        mMenuMem.add(jMenuM2);

        jMenuM3.setText("M3");
        jMenuM3.setActionCommand("M3");

        mCheckBoxMenuItemMemShow3.setSelected(true);
        mCheckBoxMenuItemMemShow3.setText("Show");
        mCheckBoxMenuItemMemShow3.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mCheckBoxMenuItemMemShow3ActionPerformed(evt);
            }
        });
        jMenuM3.add(mCheckBoxMenuItemMemShow3);

        mMenuItemMemCapture3.setText("Capture");
        mMenuItemMemCapture3.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuItemMemCapture3ActionPerformed(evt);
            }
        });
        jMenuM3.add(mMenuItemMemCapture3);

        mMenuMem.add(jMenuM3);

        mPopupMenu.add(mMenuMem);

        mMenuEdit.setText("Edit");

        mMenuEditTitle.setText("Title");
        mMenuEditTitle.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuEditTitleActionPerformed(evt);
            }
        });
        mMenuEdit.add(mMenuEditTitle);

        mMenuEditCaption.setText("Caption");
        mMenuEditCaption.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuEditCaptionActionPerformed(evt);
            }
        });
        mMenuEdit.add(mMenuEditCaption);

        mPopupMenu.add(mMenuEdit);

        mMenuFile.setText("File");

        mMenuItemFileExportCsv.setText("Export CSV");
        mMenuItemFileExportCsv.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuItemFileExportCsvActionPerformed(evt);
            }
        });
        mMenuFile.add(mMenuItemFileExportCsv);

        mMenuItemFileExportPng.setText("Export PNG");
        mMenuItemFileExportPng.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuItemFileExportPngActionPerformed(evt);
            }
        });
        mMenuFile.add(mMenuItemFileExportPng);

        mPopupMenu.add(mMenuFile);
        mPopupMenu.add(jSeparator1);

        mMenuPeak.setText("Peaks");

        mMenuItemPeakOff.setText("Off");
        mMenuItemPeakOff.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuItemPeakOffActionPerformed(evt);
            }
        });
        mMenuPeak.add(mMenuItemPeakOff);

        mMenuItemPeakPick3.setText("3");
        mMenuItemPeakPick3.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuItemPeakPick3ActionPerformed(evt);
            }
        });
        mMenuPeak.add(mMenuItemPeakPick3);

        mMenuItemPeakPick6.setText("6");
        mMenuItemPeakPick6.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuItemPeakPick6ActionPerformed(evt);
            }
        });
        mMenuPeak.add(mMenuItemPeakPick6);

        mMenuItemPeakPick9.setText("9");
        mMenuItemPeakPick9.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuItemPeakPick9ActionPerformed(evt);
            }
        });
        mMenuPeak.add(mMenuItemPeakPick9);

        mPopupMenu.add(mMenuPeak);

        mMenuMarkers.setText("Markers");

        mMenuMarkersAllOn.setText("All On");
        mMenuMarkersAllOn.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuMarkersAllOnActionPerformed(evt);
            }
        });
        mMenuMarkers.add(mMenuMarkersAllOn);

        mMenuMarkersAllOff.setText("All Off");
        mMenuMarkersAllOff.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuMarkersAllOffActionPerformed(evt);
            }
        });
        mMenuMarkers.add(mMenuMarkersAllOff);

        mMenuMarkersNextActive.setText("Next Active");
        mMenuMarkersNextActive.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mMenuMarkersNextActiveActionPerformed(evt);
            }
        });
        mMenuMarkers.add(mMenuMarkersNextActive);

        mPopupMenu.add(mMenuMarkers);
    }// </editor-fold>//GEN-END:initComponents

    private void mCheckBoxMenuItemEnvShowActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mCheckBoxMenuItemEnvShowActionPerformed
        mXyDisplay.setEnvVisible( mCheckBoxMenuItemEnvShow.isSelected() );
        mXyDisplay.repaint();
    }//GEN-LAST:event_mCheckBoxMenuItemEnvShowActionPerformed

    private void mCheckBoxMenuItemEnvActiveActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mCheckBoxMenuItemEnvActiveActionPerformed
        mXyDisplay.setEnvActive( mCheckBoxMenuItemEnvActive.isSelected() );
        mXyDisplay.repaint();
    }//GEN-LAST:event_mCheckBoxMenuItemEnvActiveActionPerformed

    private void mCheckBoxMenuItemMemShow0ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mCheckBoxMenuItemMemShow0ActionPerformed
        mXyDisplay.setMemVisible( 0, mCheckBoxMenuItemMemShow0.isSelected() );
        mXyDisplay.repaint();
    }//GEN-LAST:event_mCheckBoxMenuItemMemShow0ActionPerformed

    private void mMenuItemMemCapture0ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuItemMemCapture0ActionPerformed
        mXyDisplay.setMemCopyXy( 0 );
        mXyDisplay.setMemVisible( 0, true );
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuItemMemCapture0ActionPerformed

    private void mMenuEditTitleActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuEditTitleActionPerformed
        String str;
        
        // Get the current title string
        str = mXyDisplay.getTitleStr();
        
        // Show a modal dialog to get new string
        str = (String)JOptionPane.showInputDialog("Enter New Title",str);
        
        // Set the title if valid input
        if ((str != null) && (str.length() > 0)) {
                mXyDisplay.setTitleStr( str );
        }
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuEditTitleActionPerformed

    private void mMenuEditCaptionActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuEditCaptionActionPerformed
        String str;
        
        // Get the current title string
        str = mXyDisplay.getCaptionStr();
        
        // Show a modal dialog to get new string
        str = (String)JOptionPane.showInputDialog("Enter New Caption",str);
        
        // Set the title if valid input
        if ((str != null) && (str.length() > 0)) {
                mXyDisplay.setCaptionStr( str );
        }
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuEditCaptionActionPerformed

    private void mMenuItemFileExportCsvActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuItemFileExportCsvActionPerformed
        
        //In response to a button click:
        int returnVal = mFileChooser.showOpenDialog(mXyDisplay);
        
        if (returnVal == JFileChooser.APPROVE_OPTION) {
            System.out.println("Selected: "+mFileChooser.getSelectedFile());
        } else {
            System.out.println("Selected: cancelled");
            return;
        }

        mXyDisplay.ExportCsv( mFileChooser.getSelectedFile() );
    }//GEN-LAST:event_mMenuItemFileExportCsvActionPerformed

    private void mMenuItemFileExportPngActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuItemFileExportPngActionPerformed
                
        //In response to a button click:
        int returnVal = mFileChooser.showOpenDialog(mXyDisplay);
        
        if (returnVal == JFileChooser.APPROVE_OPTION) {
            System.out.println("Selected: "+mFileChooser.getSelectedFile());
        } else {
            System.out.println("Selected: cancelled");
            return;
        }

        mXyDisplay.ExportPng( mFileChooser.getSelectedFile() );
    }//GEN-LAST:event_mMenuItemFileExportPngActionPerformed

    private void mMenuItemPeakOffActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuItemPeakOffActionPerformed
        mXyDisplay.SetPeakPickCount(0);
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuItemPeakOffActionPerformed

    private void mMenuItemPeakPick3ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuItemPeakPick3ActionPerformed
        mXyDisplay.SetPeakPickCount(3);
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuItemPeakPick3ActionPerformed

    private void mMenuItemPeakPick6ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuItemPeakPick6ActionPerformed
        mXyDisplay.SetPeakPickCount(6);
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuItemPeakPick6ActionPerformed

    private void mMenuItemPeakPick9ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuItemPeakPick9ActionPerformed
        mXyDisplay.SetPeakPickCount(9);
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuItemPeakPick9ActionPerformed

    private void mMenuMarkersAllOnActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuMarkersAllOnActionPerformed
        mXyDisplay.setMarkersVisible(true);
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuMarkersAllOnActionPerformed

    private void mMenuMarkersAllOffActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuMarkersAllOffActionPerformed
        mXyDisplay.setMarkersVisible(false);
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuMarkersAllOffActionPerformed

    private void mMenuMarkersNextActiveActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuMarkersNextActiveActionPerformed
        int idx,act;
        
        act = 0;
        for(idx=0;idx<mXyDisplay.getMarkerCount();idx++){
           if( mXyDisplay.getMarkerActive(idx) ){
               act = idx;
           }    
        }
        
        act = (act+1)%mXyDisplay.getMarkerCount();
        mXyDisplay.setMarkerActive(act);
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuMarkersNextActiveActionPerformed

    private void mCheckBoxMenuItemMemShow1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mCheckBoxMenuItemMemShow1ActionPerformed
        mXyDisplay.setMemVisible( 1, mCheckBoxMenuItemMemShow1.isSelected() );
        mXyDisplay.repaint();
    }//GEN-LAST:event_mCheckBoxMenuItemMemShow1ActionPerformed

    private void mMenuItemMemCapture1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuItemMemCapture1ActionPerformed
        mXyDisplay.setMemCopyXy( 1 );
        mXyDisplay.setMemVisible( 1, true );
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuItemMemCapture1ActionPerformed

    private void mCheckBoxMenuItemMemShow2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mCheckBoxMenuItemMemShow2ActionPerformed
        mXyDisplay.setMemVisible( 2, mCheckBoxMenuItemMemShow2.isSelected() );
        mXyDisplay.repaint();
    }//GEN-LAST:event_mCheckBoxMenuItemMemShow2ActionPerformed

    private void mMenuItemMemCapture2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuItemMemCapture2ActionPerformed
        mXyDisplay.setMemCopyXy( 2 );
        mXyDisplay.setMemVisible( 2, true );
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuItemMemCapture2ActionPerformed

    private void mCheckBoxMenuItemMemShow3ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mCheckBoxMenuItemMemShow3ActionPerformed
        mXyDisplay.setMemVisible( 3, mCheckBoxMenuItemMemShow3.isSelected() );
        mXyDisplay.repaint();
    }//GEN-LAST:event_mCheckBoxMenuItemMemShow3ActionPerformed

    private void mMenuItemMemCapture3ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mMenuItemMemCapture3ActionPerformed
        mXyDisplay.setMemCopyXy( 3 );
        mXyDisplay.setMemVisible( 3, true );
        mXyDisplay.repaint();
    }//GEN-LAST:event_mMenuItemMemCapture3ActionPerformed

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JMenu jMenuM0;
    private javax.swing.JMenu jMenuM1;
    private javax.swing.JMenu jMenuM2;
    private javax.swing.JMenu jMenuM3;
    private javax.swing.JPopupMenu.Separator jSeparator1;
    private javax.swing.JCheckBoxMenuItem mCheckBoxMenuItemEnvActive;
    private javax.swing.JCheckBoxMenuItem mCheckBoxMenuItemEnvShow;
    private javax.swing.JCheckBoxMenuItem mCheckBoxMenuItemMemShow0;
    private javax.swing.JCheckBoxMenuItem mCheckBoxMenuItemMemShow1;
    private javax.swing.JCheckBoxMenuItem mCheckBoxMenuItemMemShow2;
    private javax.swing.JCheckBoxMenuItem mCheckBoxMenuItemMemShow3;
    private javax.swing.JMenu mMenuEdit;
    private javax.swing.JMenuItem mMenuEditCaption;
    private javax.swing.JMenuItem mMenuEditTitle;
    private javax.swing.JMenu mMenuEnvelope;
    private javax.swing.JMenu mMenuFile;
    private javax.swing.JMenuItem mMenuItemFileExportCsv;
    private javax.swing.JMenuItem mMenuItemFileExportPng;
    private javax.swing.JMenuItem mMenuItemMemCapture0;
    private javax.swing.JMenuItem mMenuItemMemCapture1;
    private javax.swing.JMenuItem mMenuItemMemCapture2;
    private javax.swing.JMenuItem mMenuItemMemCapture3;
    private javax.swing.JMenuItem mMenuItemPeakOff;
    private javax.swing.JMenuItem mMenuItemPeakPick3;
    private javax.swing.JMenuItem mMenuItemPeakPick6;
    private javax.swing.JMenuItem mMenuItemPeakPick9;
    private javax.swing.JMenu mMenuMarkers;
    private javax.swing.JMenuItem mMenuMarkersAllOff;
    private javax.swing.JMenuItem mMenuMarkersAllOn;
    private javax.swing.JMenuItem mMenuMarkersNextActive;
    private javax.swing.JMenu mMenuMem;
    private javax.swing.JMenu mMenuPeak;
    private javax.swing.JPopupMenu mPopupMenu;
    // End of variables declaration//GEN-END:variables
}
